package com.zh.springcloud.feign;

import com.zh.springcloud.common.Result;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestParam;

/**
 * @Description:
 * @ClassName StorageFeignService
 * @date: 2021.08.12 13:24
 * @Author: zhanghang
 */
@FeignClient(value = "seata-storage-service")
public interface StorageFeignService {

	/**
	 * description: 减库存
	 * date: 2021年-08月-12日 18:11
	 * author: zhanghang
	 *
	 * @param productId
 * @param count
	 * @return com.zh.springcloud.common.Result<?>
	 */
	@PostMapping("/storage/decrease")
	Result<?> decrease(@RequestParam("productId") Long productId, @RequestParam("count")Integer count);
}
